/* Layout */
import Layout from '../views/layout/Layout';

const _import = require(`./_import_${process.env.NODE_ENV}`);
const systemRoutes = [
  {
    path: '/system',
    component: Layout,
    // meta: { roles: [] }, // you can set roles in root nav
    redirect: 'noredirect',
    name: 'system',
    meta: {
      title: '系统设置',
      icon: 'component',
      roles: [],
    },
    children: [
      {
        path: 'system-log',
        name: 'system-log',
        component: _import('system/opLog'),
        meta: {
          title: '操作日志',
          roles: [],
        },
      },
      // {
      //   path: 'system-argument',
      //   name: 'system-argument',
      //   component: _import('system/setting'),
      //   meta: {
      //     title: '系统参数设置',
      //     roles: []
      //   }
      // },
      {
        path: 'system-interface',
        name: 'system-interface',
        component: _import('system/interface'),
        meta: {
          title: '接口管理',
          notLog: true,
          // roles: ['system.op.view'],
          roles: ['msg', 'card', 'msg-switch', 'card-switch', 'inter-msg-switch', 'inter-msg'],
        },
      },
      {
        path: 'system-app-version',
        name: 'system-app-version',
        component: _import('system/appVersion'),
        meta: {
          title: '手机版本更新',
          // roles: ['system.op.view'],
          roles: [],
        },
      },
      {
        path: 'system-ios-manage',
        name: 'system-ios-manage',
        component: _import('system/iosManage'),
        meta: {
          title: 'iOS证书管理',
          roles: [],
        },
      },
      {
        path: 'registration-management',
        name: 'registration-management',
        component: _import('system/regiestManage'),
        meta: {
          title: '限制管理',
          roles: ['on-off', 'save', 'checkOnOff'],
        },
      },
    ],
  },
];
export default systemRoutes;
